<template>
	<view class="" style="width: 100%;height: 100%;">
		<view class="header_box">
			<view class="header">
				<view class="tc flex-1" @click="orderFunct(1)"><text :class="order_type==1?'header_item active':'header_item'">当前订单</text></view>
				<view class="tc flex-1" @click="orderFunct(2)"><text :class="order_type==2?'header_item active':'header_item'">历史订单</text></view>
			</view>
			<view class="d-a-c" style="height: 60rpx;" v-if="order_type==2">
				<view class="flex-1 tc" @click="deliveryFunct(0)"><text :class="delivery_type==0?'delivery_active':'delivery'">全部</text></view>
				<view class="flex-1 tc" @click="deliveryFunct(20)"><text :class="delivery_type==20?'delivery_active':'delivery'">自提</text></view>
				<view class="flex-1 tc" @click="deliveryFunct(10)"><text :class="delivery_type==10?'delivery_active':'delivery'">外卖</text></view>
			</view>
		</view>
		<view v-if="listData.length==0" class="d-flex w-100 h-100 flex-column just-content-center align-items-center">
			<image src="/static/images/loading.gif" class="drinks-img"></image>
			<view class="tips d-flex flex-column align-items-center font-size-base text-color-assist">
				<view>您还没有点单</view>
				<view>快去犒劳一下自己吧~</view>
			</view>
			<button type="primary" class="drink-btn" size="default" @tap="menu">去点餐</button>
		</view>
		<template v-else>
			<view class="order-box" v-if="listData.length==1&&listData[0].pay_status.value!=10">
				<view class="bg-white">
					<view class="section">
						<!-- store info begin -->
						<!-- store info end -->
						<list-cell :hover="false" padding="50rpx 30rpx">
							<view class="w-100 d-flex flex-column">
								<view class="d-flex align-items-center just-content-center" v-if="listData[0].pay_status.value == 20">
									<view class="sort-num" v-if="listData[0].order_status.value == 21">待审核</view>
									<view class="sort-num" v-else>{{ listData[0].meal_code }}</view>
								</view>
								<view class="d-flex align-items-center just-content-center" v-if="listData[0].pay_status.value == 10">
									<view class="sort-num">待支付</view>
								</view>
								<view class="d-flex align-items-center just-content-center" v-if="listData[0].pay_status.value == 10">
									<view class="f26 pay_btn" @click="onPayOrder(listData[0].order_id)">付款</view>
								</view>
								
								<!-- steps begin -->
								<view class="d-flex just-content-center" v-if="listData[0].pay_status.value == 20">
									<view class="steps d-flex flex-column" :class="{'w-80': listData[0].delivery_type.value == 10, 'w-100': listData[0].delivery_type.value == 20}">
										<view class="steps__img-column">
											<view class="steps__img-column-item">
												<image src="/static/images/order/ordered_selected.png" v-if="listData[0].pay_status.value == 20"></image>
												<image src="/static/images/order/ordered_selected.png" v-else></image>
											</view>
											<view class="steps__img-column-item" :class="{active: listData[0].delivery_status.value >= 10}">
												<image src="/static/images/order/production_selected.png" v-if="listData[0].delivery_status.value >= 10"></image>
												<image src="/static/images/order/production.png" v-else></image>
											</view>
											<view class="steps__img-column-item" :class="{active: listData[0].delivery_status.value == 20}" v-if="listData[0].delivery_type.value == 10">
												<image src="/static/images/order/delivery_selected.png" v-if="listData[0].delivery_status.value == 20"></image>
												<image src="/static/images/order/delivered.png" v-else></image>
											</view>
											<view class="steps__img-column-item" :class="{active: listData[0].order_status.value == 20}">
												<image src="/static/images/order/delivered_selected.png" v-if="listData[0].order_status.value == 20"></image>
												<image src="/static/images/order/delivered.png" v-else></image>
											</view>
										</view>
										<view class="steps__text-column">
											<view class="steps__text-column-item" :class="{active: listData[0].pay_status.value == 20}">
												<view class="steps__column-item-line bg-transparent"></view>
												<view class="steps__text-column-item-text">已下单</view>
												<view class="steps__column-item-line"></view>
											</view>

											<view class="steps__text-column-item" :class="{active: listData[0].delivery_status.value == 20}">
												<view class="steps__column-item-line"></view>
												<view class="steps__text-column-item-text">{{ listData[0].delivery_type.value == 10 ? '待接单' : '待取餐' }}</view>
												<view class="steps__column-item-line"></view>
											</view>
											<view v-if="listData[0].delivery_type.value == 10" class="steps__text-column-item" :class="{active: listData[0].delivery_status.value == 20}">
												<view class="steps__column-item-line"></view>
												<view class="steps__text-column-item-text">配送中</view>
												<view class="steps__column-item-line"></view>
											</view>
											<view class="steps__text-column-item" :class="{active: listData[0].receipt_status.value == 20}">
												<view class="steps__column-item-line"></view>
												<view class="steps__text-column-item-text">
													{{ listData[0].delivery_type.value == 10 ? '已送达' : '已取餐' }}
												</view>
												<view class="steps__column-item-line bg-transparent"></view>
											</view>
										</view>
									</view>
								</view>
								
								<!-- steps end -->
								<!-- 			<view v-if="order.status<=1" class="d-flex just-content-center align-items-center font-size-base text-color-assist mb-40">
									您前面还有 <text class="text-color-primary mr-10 ml-10">4</text> 单待制作
								</view> -->
								<!-- goods begin -->
								<view class="w-100 d-flex flex-column position-relative mt-30" style="margin-bottom: -40rpx;">
									<view class="w-100 d-flex align-items-center mb-40" v-for="(good, index) in listData[0].product" :key="index">
										<view class="d-flex flex-column w-60 overflow-hidden">
											<view class="font-size-lg text-color-base mb-10 text-truncate">{{ good.product_name }}</view>
											<view class="font-size-sm text-color-assist text-truncate">{{ good.product_attr }}</view>
										</view>
										<view class="d-flex w-40 align-items-center justify-content-between pl-30">
											<view class="font-size-base text-color-base">x{{ good.total_num }}</view>
											<view class="font-size-base text-color-base font-weight-bold">￥{{ good.total_pay_price }}</view>
										</view>
									</view>
								</view>
								<!-- goods end -->
							</view>
						</list-cell>
					</view>
					<view class="section">
						<!-- payment and amount begin -->
						<list-cell :hover="false" padding="50rpx 30rpx">
							<view class="w-100 d-flex flex-column">
								<view class="pay-cell">
									<view>支付方式</view>
									<view class="font-weight-bold">{{ listData[0].pay_type.text }}</view>
								</view>
								<view class="pay-cell">
									<view>金额总计</view>
									<view class="font-weight-bold">￥{{ listData[0].pay_price }}</view>
								</view>
							</view>
						</list-cell>
						<!-- payment and amount end -->
					</view>
					<view class="section">
						<!-- order info begin -->
						<list-cell :hover="false" padding="50rpx 30rpx">
							<view class="w-100 d-flex flex-column">
								<view class="pay-cell">
									<view>下单时间</view>
									<view class="font-weight-bold">{{listData[0].create_time}}</view>
								</view>
								<!-- 								<view class="pay-cell">
									<view>下单门店</view>
									<view class="font-weight-bold">{{ listData[0].store.name }}</view>
								</view> -->
								<view class="pay-cell">
									<view>支付方式</view>
									<view class="font-weight-bold">{{ listData[0].pay_type.text }}</view>
								</view>
								<view class="pay-cell">
									<view>订单号</view>
									<view class="font-weight-bold">{{ listData[0].order_no }}</view>
								</view>
							</view>
						</list-cell>
						<!-- order info end -->
					</view>
					<!-- order other info begin -->
					<list-cell :hover="false" padding="50rpx 30rpx 20rpx" last>
						<view class="w-100 d-flex flex-column">
							<view class="pay-cell">
								<view>取单号</view>
								<view class="font-weight-bold">{{ listData[0].meal_code }}</view>
							</view>
							<view class="pay-cell" v-if="listData[0].delivery_type.value==20">
								<view>取餐时间</view>
								<view class="font-weight-bold">{{ listData[0].mealtime }}</view>
							</view>
							<view class="pay-cell" v-if="listData[0].delivery_type.value==10">
								<view>预计送达时间</view>
								<view class="font-weight-bold">{{ listData[0].mealtime }}</view>
							</view>
							<view class="pay-cell">
								<view>享用方式</view>
								<view class="font-weight-bold">{{listData[0].delivery_type.text}}</view>
							</view>
							<!-- <view class="pay-cell">
								<view>取餐时间</view>
								<view class="font-weight-bold">立即取餐</view>
							</view> -->
							<!-- 							<view class="pay-cell">
								<view>完成制作时间</view>
								<view class="font-weight-bold">{{ listData[0].productioned_time }}</view>
							</view> -->
							<view class="pay-cell">
								<view>备注</view>
								<view class="font-weight-bold">{{ listData[0].postscript }}</view>
							</view>
						</view>
					</list-cell>
					<!-- order other info end -->
				</view>
			</view>
			<view v-else>
				<scroll-view scroll-y="true" class="scroll-Y" :style="'height:' + scrollviewHigh + 'px;'" lower-threshold="50" @scrolltolower="scrolltolowerFunc">
					<view :class="topRefresh ? 'top-refresh open' : 'top-refresh'"><view class="circle" v-for="(circle, n) in 3" :key="n"></view></view>
					<view class="order-list">
						<view class="item" v-for="(item, index) in listData" :key="index">
							<view class="order-head d-b-c" style="60rpx">
								<view class="mb-20">
									<text class="state-text">{{ item.delivery_type.value==20?'自取':'外卖' }}</text>
									<text class="shop-name flex-1 fb" v-if="item.meal_code!=0">取餐码：{{ item.meal_code }}</text>
								</view>
								<view class="state">
									<text class="red">{{ item.state_text }}</text>
								</view>
							</view>
							<!--多个商品显示-->
							<view class="product-list pr" style="box-sizing: content-box;" v-if="item.product.length > 1" @click="gotoDetail(item.order_id)">
								<scroll-view scroll-x="true">
									<view class="list d-s-c pr100">
										<view class="cover mr10" v-for="(img, num) in item.product" :key="num"><image :src="img.image.file_path" mode="aspectFit"></image></view>
									</view>
								</scroll-view>
								<view class="total-count">
									<view class="left-shadow"></view>
									<view class="price f22">
										¥
										<text class="f40">{{ item.order_price }}</text>
									</view>
									<view class="count">共{{ item.product.length }}件</view>
								</view>
							</view>
							<!--一个商品显示-->
							<view class="one-product d-s-c" v-else @click="gotoDetail(item.order_id)">
								<view class="cover" v-for="(img, num) in item.product" :key="num"><image :src="img.image.file_path" mode="aspectFit"></image></view>
								<view class="pro-info flex-1">{{ item.product[0].product_name }}</view>
								<view class="total-count">
									<view class="left-shadow"></view>
									<view class="price f22">
										¥
										<text class="f40">{{ item.pay_price }}</text>
									</view>
									<view class="count">共{{ item.product[0].total_num }}件</view>
								</view>
							</view>
							<view class="order-bts">
								<block v-if="item.order_status.value != 20">
									<!-- 未支付取消订单 -->
									<button @click="cancelOrder(item.order_id)" type="default" v-if="item.pay_status.value == 10">取消</button>
									<!-- 已支付取消订单 -->
									<block v-if="item.order_status.value != 21">
										<block v-if="item.pay_status.value == 20 && item.delivery_status.value == 10">
											<button @click="cancelOrder(item.order_id)" type="default">申请取消</button>
										</block>
										<!-- 订单核销码 -->
										<!-- <block v-if="item.pay_status.value == 20 && item.delivery_type.value == 20 && item.delivery_status.value == 10">
											<button @click="onQRCode(item.order_id)">核销码</button>
										</block> -->
									</block>
									<text v-else class="count">取消申请中</text>
									<!-- 订单付款 -->
									<block v-if="item.pay_status.value == 10"><button class="btn-paotui" @click="onPayOrder(item.order_id)">付款</button></block>
									<!-- 确认收货 -->
									<block v-if="item.delivery_status.value == 20 && item.receipt_status.value == 10"><button @click="orderReceipt(item.order_id)">确认收货</button></block>
									<!-- 订单评价 -->
									<button type="default" v-if="item.order_status.value == 30 && item.is_comment == 0" @click="gotoEvaluate(item.order_id)">评价</button>
								</block>
								<template v-if="item.assemble_status == 10 && item.order_source == 30">
									<button class="btn-paotui" @click="gotoAssembleShare(item.product[0].bill_source_id)">邀请好友拼单</button>
								</template>
							</view>
						</view>
						<view class="d-c-c p30" v-if="listData.length == 0 && !loading">
							<text class="iconfont icon-wushuju"></text>
							<text class="cont">亲，暂无相关记录哦</text>
						</view>
						<uni-load-more v-else :loadingType="loadingType"></uni-load-more>
					</view>
				</scroll-view>
			</view>
		</template>
		<!--支付选择-->
		<Popup :show="isPayPopup" msg="支付方式" @hidePopup="hidePopupFunc">
			<!--支付方式-->
			<view class="buy-checkout">
			<!-- 	<view :class="pay_type == 20 ? 'item active border-b-e' : 'item border-b-e'" @click="payTypeFunc(20)">
					<view class="d-s-c">
						<view class="icon-box d-c-c mr10"><span class="icon iconfont icon-weixin"></span></view>
						<text class="key">微信支付</text>
					</view>
					<view class="icon-box d-c-c"></view>
				</view> -->
				<view  :class="pay_type == 30 ? 'item active border-b-e' : 'item border-b-e'" @click="payTypeFunc(30)">
					<view class="d-s-c">
						<view class="icon-box d-c-c mr10"><span class="icon iconfont icon-zhifubao"></span></view>
						<text class="key">支付宝支付</text>
					</view>
					<view class="icon-box d-c-c"></view>
				</view>
				<view :class="pay_type == 10 ? 'item active' : 'item'" @click="payTypeFunc(10)">
					<view class="d-s-c">
						<view class="icon-box d-c-c mr10"><span class="icon iconfont icon-yue"></span></view>
						<text class="key">余额支付</text>
					</view>
					<view class="icon-box d-c-c"></view>
				</view>
			</view>
			<view class="bts"></view>
		</Popup>
	</view>
</template>

<script>
	import uniLoadMore from "@/components/uni-load-more.vue"
	import Popup from '@/components/uni-popup.vue';
	import { pay } from '@/common/pay.js';
	export default {
		components: {
			uniLoadMore,
			Popup
		},
		data() {
			return {
				delivery_type: 0,
				order_type: 1,
				/*手机高度*/
				phoneHeight: 0,
				/*可滚动视图区域高度*/
				scrollviewHigh: 0,
				/*状态选中*/
				state_active: 0,
				/*顶部刷新*/
				topRefresh: false,
				/*数据*/
				listData: [],
				/*数据类别*/
				dataType: 'all',
				/*是否显示支付类别弹窗*/
				isPayPopup: false,
				/*支付方式*/
				pay_type: 20,
				/*订单id*/
				order_id: 0,
				/*最后一页码数*/
				last_page: 0,
				/*当前页面*/
				page: 1,
				/*每页条数*/
				list_rows: 10,
				/*有没有等多*/
				no_more: false,
				/*是否正在加载*/
				loading: false,
				/*是否显示核销二维码*/
				isCodeImg: false,
				codeImg: '',
				/*是否显示支付宝支付，只有在h5，非微信内打开才显示*/
				showAlipay: false
			}
		},
		onShow() {
			let self=this;
			setTimeout(function() {
				self.init();
				self.orderFunct(1);
			}, 300);
		},
		computed: {
			/*加载中状态*/
			loadingType() {
				if (this.loading) {
					return 1;
				} else {
					if (this.listData.length != 0 && this.no_more) {
						return 2;
					} else {
						return 0;
					}
				}
			},
		},
		methods: {
			
			/*可滚动视图区域到底触发*/
			scrolltolowerFunc() {
				let self = this;
				if (self.no_more) {
					return;
				}
				self.page++;
				if (self.page <= self.last_page) {
					self.getData();
				} else {
					self.no_more = true;
				}
			},
			init() {
				let self = this;
				uni.getSystemInfo({
					success(res) {
						self.phoneHeight = res.windowHeight;
						// 计算组件的高度
						let view = uni.createSelectorQuery().select('.header_box');
						view.boundingClientRect(data => {
							let h = self.phoneHeight - data.height;
							self.scrollviewHigh = h;
						}).exec();
					}
				});
				this.page = 1;
				this.no_more=false;
				this.listData = [];
			},
			/*获取数据*/
			getData() {
				let self = this;
				self.loading = true;
				uni.showLoading({
					title:'加载中'
				})
				self._get(
					'user.order/lists', {
						order_type: self.order_type,
						delivery_type: self.delivery_type,
						page: self.page,
					},
					function(res) {
						self.loading = false;
						self.listData = self.listData.concat(res.data.list.data);
						console.log(self.listData)
						self.last_page = res.data.list.last_page;
						if (res.data.list.last_page <= 1) {
							self.no_more = true;
						} else {
							self.no_more = false;
						}
						//#ifdef H5
						if (!self.isWeixin() && res.data.h5_alipay) {
							self.showAlipay = true;
						}
						//#endif
						if (self.listData.length == 1) {
							self.getdetail(self.listData[0].order_id)
						}
						uni.hideLoading()
					}
				);
			},
			getdetail(id) {
				let self = this;
				self._get(
					'user.order/detail', {
						order_id: id
					},
					function(res) {
						self.detail = res.data.order;
						self.extractStore = res.data.order.extractStore;
						self.service_open = res.data.setting.service_open;
						if (res.data.setting.mp_service == null) {
							self.service_type = 10;
						} else {
							self.service_type = res.data.setting.mp_service.service_type;
						}
						//#ifdef H5
						if (!self.isWeixin() && res.data.h5_alipay) {
							self.showAlipay = true;
						}
						//#endif
						self.loadding = false;
						uni.hideLoading();
					}
				);
			},
			deliveryFunct(n){
				if(this.loading){
					return
				}
				this.delivery_type = n;
				this.init();
				this.getData();
			},
			orderFunct(n) {
				if(this.loading){
					return
				}
				this.order_type = n;
				this.delivery_type = 0;
				this.init();
				this.getData();
			},
			orders() {
				uni.navigateTo({
					url: '/pages/orders/orders'
				})
			},
			menu() {
				uni.switchTab({
					url: '/pages/menu/menu?orderType=takein'
				})
			},
			/*跳转页面*/
			gotoDetail(e) {
				uni.navigateTo({
					url: '/pages/order/order-detail?order_id=' + e
				});
			},
			
			/*隐藏支付方式*/
			hidePopupFunc() {
				this.isPayPopup = false;
			},
			
			/*去支付*/
			payTypeFunc(payType) {
				let self = this;
				self.isPayPopup = false;
				uni.showLoading({
					title: '加载中'
				});
				self._post(
					'user.order/pay',
					{
						payType: payType,
						order_id: self.order_id,
						pay_source: self.getPlatform()
					},
					function(res) {
						pay(res, self);
					}
				);
			},
			
			/*支付方式选择*/
			onPayOrder(orderId) {
				let self = this;
				self.isPayPopup = true;
				self.order_id = orderId;
			},
			
			/*确认收货*/
			orderReceipt(order_id) {
				let self = this;
				wx.showModal({
					title: '提示',
					content: '您确定要收货吗?',
					success: function(o) {
						if (o.confirm) {
							uni.showLoading({
								title: '正在处理'
							});
							self._post(
								'user.order/receipt',
								{
									order_id: order_id
								},
								function(res) {
									uni.hideLoading();
									uni.showToast({
										title: res.msg,
										duration: 2000,
										icon: 'success'
									});
									self.listData = [];
									self.getData();
								}
							);
						} else {
							uni.showToast({
								title: '取消收货',
								duration: 1000,
								icon: 'none'
							});
						}
					}
				});
			},
			
			/*取消订单*/
			cancelOrder(e) {
				let self = this;
				let order_id = e;
				wx.showModal({
					title: '提示',
					content: '您确定要取消吗?',
					success: function(o) {
						if (o.confirm) {
							uni.showLoading({
								title: '正在处理'
							});
							self._get(
								'user.order/cancel',
								{
									order_id: order_id
								},
								function(res) {
									uni.hideLoading();
									uni.showToast({
										title: '操作成功',
										duration: 2000,
										icon: 'success'
									});
									self.listData = [];
									self.getData();
								}
							);
						}
					}
				});
			},
			/*去评论*/
			gotoEvaluate(e) {
				uni.navigateTo({
					url: '/pages/order/evaluate/evaluate?order_id=' + e
				});
			},
		}
	}
</script>

<style lang="scss" scoped>
	/* #ifdef H5 */
	page {
		min-height: 100%;
		background-color: $bg-color;
	}

	/* #endif */
	.order-box {
		padding: 20rpx;
		/* #ifdef H5 */
		margin-bottom: 100rpx;
		/* #endif */
	}

	.drinks-img {
		width: 260rpx;
		height: 260rpx;
	}

	.tips {
		margin: 60rpx 0 80rpx;
		line-height: 48rpx;
	}

	.drink-btn {
		width: 320rpx;
		border-radius: 50rem !important;
		margin-bottom: 40rpx;
		font-size: 32rpx;
		line-height: 3.0;
		background-color: #f5a654;
		border: #f5a654;
	}

	@mixin arch {
		content: "";
		position: absolute;
		background-color: $bg-color;
		width: 30rpx;
		height: 30rpx;
		bottom: -15rpx;
		z-index: 10;
		border-radius: 100%;
	}

	.section {
		position: relative;

		&::before {
			@include arch;
			left: -15rpx;
		}

		&::after {
			@include arch;
			right: -15rpx;
		}
	}

	.pay-cell {
		width: 100%;
		display: flex;
		align-items: center;
		justify-content: space-between;
		font-size: $font-size-base;
		color: $text-color-base;
		margin-bottom: 40rpx;

		&:nth-last-child(1) {
			margin-bottom: 0;
		}
	}

	.sort-num {
		font-size: 64rpx;
		font-weight: bold;
		color: $text-color-base;
		line-height: 2;
	}

	.steps__img-column {
		display: flex;
		margin: 30rpx 0;

		.steps__img-column-item {
			flex: 1;
			display: flex;
			align-items: center;
			justify-content: center;

			image {
				width: 80rpx;
				height: 80rpx;
			}
		}
	}

	.steps__text-column {
		display: flex;
		margin-bottom: 40rpx;

		.steps__text-column-item {
			flex: 1;
			display: inline-flex;
			display: flex;
			align-items: center;
			justify-content: center;
			font-size: $font-size-base;
			color: $text-color-assist;

			&.active {
				color: $text-color-base;
				font-weight: bold;

				.steps__column-item-line {
					background-color: $text-color-base;
				}
			}

			.steps__column-item-line {
				flex: 1;
				height: 2rpx;
				background-color: #919293;
				transform: scaleY(0.5);
			}

			.steps__text-column-item-text {
				margin: 0 8px;
			}
		}
	}

	.header {
		width: 100%;
		height: 100rpx;
		line-height: 100rpx;
		display: flex;
		align-items: center;
		justify-content: center;
		background-color: #FFFFFF;
		overflow: hidden;
	}

	.header_item {
		color: #999999;
		font-size: 32rpx;
		padding: 24rpx 18rpx;
		border-bottom: 6rpx solid #FFFFFF;
	}

	.header .active {
		color: #000000;
		border-bottom: 6rpx solid #f5a654;
	}
	.order-list .order-head .state-text {
		padding: 4rpx 8rpx;
		margin-right: 10rpx;
		border-radius: 4rpx;
		background: #f5a654;
		color: #ffffff;
	}
	
	.order-list .item {
		margin-top: 30rpx;
		padding: 30rpx;
		background: #ffffff;
	}
	
	.order-list .product-list,
	.order-list .one-product {
		padding: 20rpx 0;
		height: 160rpx;
	}
	
	.one-product .pro-info {
		padding: 0 30rpx;
		display: -webkit-box;
		overflow: hidden;
		-webkit-line-clamp: 2;
		-webkit-box-orient: vertical;
		font-size: 28rpx;
		color: #666666;
	}
	
	.order-list .cover,
	.order-list .cover image {
		width: 160rpx;
		height: 160rpx;
	}
	
	.order-list .total-count {
		padding-left: 20rpx;
		display: flex;
		flex-direction: column;
		justify-content: center;
		align-items: flex-end;
	}
	
	.total-count .count {
		padding-top: 10rpx;
		color: #666;
		font-size: 28rpx;
	}
	
	.product-list .total-count {
		position: absolute;
		top: 0;
		right: 0;
		bottom: 0;
		background: rgba(255, 255, 255, 0.9);
	}
	
	.product-list .total-count .left-shadow {
		position: absolute;
		top: 0;
		bottom: 0;
		left: -24rpx;
		width: 24rpx;
		overflow: hidden;
	}
	
	.product-list .total-count .left-shadow::after {
		position: absolute;
		top: 0;
		bottom: 0;
		width: 24rpx;
		right: -12rpx;
		display: block;
		content: '';
		background-image: radial-gradient(rgba(0, 0, 0, 0.2) 10%, rgba(0, 0, 0, 0.1) 40%, rgba(0, 0, 0, 0) 80%);
	}
	
	.order-list .order-bts {
		display: flex;
		justify-content: flex-end;
		align-items: center;
	}
	
	.order-list .order-bts button {
		margin: 0;
		padding: 0 30rpx;
		height: 60rpx;
		line-height: 60rpx;
		margin-left: 20rpx;
		border-radius: 30rpx;
		font-size: 24rpx;
		border: 1px solid #f5a654;
		white-space: nowrap;
		background: #f5a654;
		color: #FFFFFF;
	}
	
	.order-list .order-bts button::after {
		display: none;
	}
	
	.order-list .order-bts button.btn-border-red {
		border: 1px solid $dominant-color;
		font-size: 24rpx;
		color: $dominant-color;
	}
	
	.order-list .order-bts button.btn-red {
		background: $dominant-color;
		border: 1px solid $dominant-color;
		font-size: 24rpx;
		color: #ffffff;
	}
	
	.buy-checkout {
		width: 100%;
	}
	
	.buy-checkout .item {
		min-height: 50rpx;
		line-height: 50rpx;
		padding: 20rpx;
		display: flex;
		justify-content: space-between;
		font-size: 28rpx;
	}
	
	.buy-checkout .iconfont.icon-weixin {
		color: #04be01;
		font-size: 50rpx;
	}
	
	.buy-checkout .iconfont.icon-yue {
		color: #f0de7c;
		font-size: 50rpx;
	}
	
	.buy-checkout .item.active .iconfont.icon-xuanze {
		color: #04be01;
	}
	.buy-checkout .iconfont.icon-zhifubao {
		color: #1296db;
		font-size: 50rpx;
	}
	.delivery{
		color: #999999;
	}
	.delivery_active{
		color: #f5a654;
	}
	.pay_btn{
		border: 1rpx solid #f5a654;
		color: #f5a654;
		padding: 10rpx 20rpx;
		border-radius: 20rpx;
	}
</style>
